package com.stu.mapper;

import com.github.pagehelper.Page;
import com.stu.bean.User;
import com.stu.bean.UserExample;

import java.util.Date;
import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface UserMapper {
    long countByExample(UserExample example);

    int deleteByExample(UserExample example);

    int deleteByPrimaryKey(Integer userid);

    int insert(User record);

    int insertSelective(User record);

    List<User> selectByExample(UserExample example);

    User selectByPrimaryKey(Integer userid);

    int updateByExampleSelective(@Param("record") User record, @Param("example") UserExample example);

    int updateByExample(@Param("record") User record, @Param("example") UserExample example);

    int updateByPrimaryKeySelective(User record);

    int updateByPrimaryKey(User record);

    User selectByAll(User user);

    String selectVip(String username);

    Page<User> selectUsers(@Param("user") User user, @Param("strDate") Date strDate, @Param("endDate") Date endDate);

    int updateUser(String username,User  user);

    User selectUserByname(String heading);
}